package com.zhuzg.common.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Data
@Component
@ConfigurationProperties(prefix = "spring.datasource")  // 配置类
// 读取spring.datasource为前缀的属性内容 根据本类属性名称与属性文件相同的进行一一对应赋值
public class DynamicDataSourceProperties {

    private String url;

    private String username;

    private String password;
}
